package cn.appsys.service.developer;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import cn.appsys.dao.backenduser.BackendUserMapper;
import cn.appsys.pojo.BackendUser;
@Service
public class BackendUserServiceImpl implements BackendUserService {
   @Resource
   private BackendUserMapper backendUserMapper;
	@Override
	public BackendUser getLoginBackendUser(String userCode, String userPassword) {
		BackendUser backendUser=new BackendUser();
		try {
			backendUser=backendUserMapper.getLoginBackendUser(userCode);
			if(!userPassword.equals(backendUser.getUserPassword())){
				backendUser=null;
			}
		} catch (Exception e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		return backendUser;
	}

}
